package org.minos.edit.controller
{
	import flash.events.Event;
	import org.puremvc.as3.interfaces.INotification;
	import org.puremvc.as3.patterns.command.SimpleCommand;
	
	/**
	 * ...
	 * @author M.ichow
	 */
	public class SelectFileCommand extends SimpleCommand
	{
		
		override public function execute( notification : INotification ) : void
		{
			super.execute( notification );
			var typeFilter : Array = [];
			
			/*switch ( notification.getType() )
			{
				case AssetsMediator.SOUND: 
					typeFilter = [ ".mp3" ];
					break;
				case AssetsMediator.MOVIE: 
					typeFilter = [ ".swf" , ".mp4" , ".flv" ];
					break;
				case AssetsMediator.SWF: 
					typeFilter = [ ".swf" ];
					break;
				default: 
			}
			
			var assets : Assets = AssetsMediator( facade.retrieveMediator( AssetsMediator.NAME ) ).assets
			assets.enabled = true;
			assets.typeFilter = typeFilter;
			assets.addEventListener( Assets.OK , onSelected );
			function onSelected( e : EditEvent ) : void
			{
				notification.getBody()[ "text" ] = e.data ? e.data.title : "";
				e.target.removeEventListener( Assets.OK , onSelected );
			}*/
		
		}
	
	}

}